package com.chixing.day06.static_demo;

public class Bank {
    //懒汉式
    private final static Bank bank = new Bank();

    //饿汉式
//    private static Bank bank;
//
//    public static Bank getInstance(){
//        if(bank == null)
//            return bank=new Bank();
//        return bank;
//    }
    public static Bank getInstance(){
        return bank;
    }

    private Bank(){}
}
